const reqComUrl='https://testapi.quanyou.com.cn/mini/v1'    //请求地址  测试环境
// const reqComUrl='https://mallapi.quanyou.com.cn/mini/v1'    //正式环境 发版路径

// const reqComUrl='http://192.168.75.87:7003/mini/v1'     //本地


const insertShareRecord = reqComUrl + '/umsShareOutRecord' // 将订阅记录保存到后端
const saveAccessFootprint = reqComUrl + '/umsMemberFootprint/saveAccessFootprint' // 保存访问足迹
const saveQuitFootprint = reqComUrl + '/umsMemberFootprint/saveQuitFootprint' // 保存退出足迹
const queryAllTemplate = reqComUrl + '/wxMsgSubscribe/queryAllTemplate' // 查询消息模板map
const insertSubscribeRecord = reqComUrl + '/wxMsgSubscribe' // 将订阅记录保存到后端
const checkExistSubscribeRecord = reqComUrl + '/wxMsgSubscribe/checkExistSubscribeRecord' // 检查是否已有订阅记录
const region = reqComUrl + '/region/all' // 查询省市区
const qpuListOfVal = reqComUrl + '/qpuListOfVal/val/' // 查询省市区
const loginAuth= reqComUrl + '/login/auth'    //登录接口-如未注册注册并登录
const loginLog= reqComUrl + '/login/loginLog'    //登录日志
const updateUserAddr= reqComUrl + '/login/updateAddress'                /////更新用户定位地址
const getAddrCode=reqComUrl+'/region/getGeographicLocation'   //经纬度换区域编码
const bandingUserInfo=reqComUrl + '/login/decryptGetUserInfo'  //完善小程序用户信息
const saveUserInfo=reqComUrl + '/login/saveUserInfo'  //完善小程序用户信息（昵称、头像等）
const getHomePage=reqComUrl + '/homePage/index'  //首页banner-配置导航数据
const getShopActivity=reqComUrl + '/mmsStoreActivity/index'  //首页banner-获取门店活动图片
const joinShopActivity=reqComUrl + '/mmsStoreActivity/join'  //首页banner-参加门店活动



const classifyData=reqComUrl + '/pmsProductNav/queryAll'  //分类导航数据
const searchShopData=reqComUrl+'/search/product'       //搜索商品
const searchClassify=reqComUrl+'/search/category'       //匹配搜索类目
const getGoodsInfoHead=reqComUrl+'/pmsProduct/info'   //SKU查询商品详情（商品详情页）
const getGoodsImgText=reqComUrl+'/pmsProduct/querySpec/'   //根据skuId查询产品图文详情和规格参数 （商品详情页）
const getGoodsSkus=reqComUrl+'/pmsProduct/querySpecName/'   //查询该商品下的SKU集合（商品详情页）
const nearbyShop=reqComUrl+'/region/listShopByDistance'   //根据当前经纬度查询附近门店
const getPricePstCode=reqComUrl+'/region/getPricePstCode'   //根据当前选择地址查询销售区域
const recommendShop=reqComUrl+'/qupStore/listShopByRecommender' //根据分享合伙人用户查询推荐门店
const validByAreaCode=reqComUrl+'/salesAreaTemplate/validByAreaCode'   //查询Sku是否在销售区域内
const queryTreeAll=reqComUrl+'/region/listProvinces'   //获取全部省
const listByParentCode=reqComUrl+'/region/listByParentCode'   //根据上级行政区划查询下级行政区划
const productCoupons=reqComUrl+'/smsCoupon/productCoupons'   //详情页查询优惠券
const receiveCoupon=reqComUrl+'/smsCoupon/receiveCoupon'   //领取优惠券
const shoppingCartCoupons=reqComUrl+'/smsCoupon/shoppingCartCoupons'   //购物车优惠券列表
const modifyProductAttr=reqComUrl+'/omsCartItem/modifyProductAttr'   //更改购物车商品属性规格
const QRCode=reqComUrl+'/partner/QRCode'   //生成二维码
const getParamByScene=reqComUrl+'/partner/getParamByScene/'   //获取二维码参数
const confirmOrder=reqComUrl+'/order/settlementOrder'   //确认订单
const createOrder=reqComUrl+'/order/createOrder'   //提交购物车普通订单
const payOrder=reqComUrl+'/order/payOrder'   //支付订单
const createDepositOrder=reqComUrl+'/order/createDepositOrder'     //提交定金订单
const queryMiniByCode=reqComUrl+'/pmsAdvertisementLocation/queryMiniByCode'   //轮播及广告图
/* 首页改版新增接口 */
const queryByContentType=reqComUrl+'/cmsContent/queryByContentType'   // 友发现模块
const sysTheme=reqComUrl+'/sysTheme/page' // 根据区域获取视觉方案
const componentData=reqComUrl+'/pcsComponent/index/page'  //分页查询
const bottomNavBar=reqComUrl+'/pcsBottomNavBar/getAll'  //底部导航查询
const queryPageSet=reqComUrl+'/pmsProductSpecialColumn/queryPageSet'  //商品专栏根据ID查询页面设置元素
const querySkuByPage=reqComUrl+'/pmsProductSpecialColumn/querySkuByPage'  //专栏商品列表查询



const geocode=reqComUrl+'/region/geocode'   //根据地址获取经纬度
const recommendGoodsList=reqComUrl+'/pmsProduct/recommend'   //为您推荐列表
const getCarItem=reqComUrl + '/omsCartItem/query'  //查询购物车列表
const getCarNumber=reqComUrl + '/omsCartItem/queryNumber'  //查询购物车商品数量
const modifyQuantity=reqComUrl + '/omsCartItem/modifyQuantity'  //修改购物车商品数量
const carAddshop=reqComUrl + '/omsCartItem/add'  //添加到购物车
const deleteCarGoods=reqComUrl + '/omsCartItem/remoIds'  //删除购物车商品-（单品+批量）
const newAddress=reqComUrl + '/umsMemberReceiveAddress'  // 新增地址
const updateDefault=reqComUrl + '/umsMemberReceiveAddress/updateDefaultStatus'  // 更新默认地址
const addressList=reqComUrl + '/umsMemberReceiveAddress/page'  // 收货地址查询
const deleteAddress=reqComUrl + '/umsMemberReceiveAddress/delete'  // 删除收货地址
const updateAddress=reqComUrl + '/umsMemberReceiveAddress/update'  // 编辑收货地址
const centerCount=reqComUrl + '/personalCenter/centerCount'  // 个人中心统计
const partnerRegister=reqComUrl + '/partner/register' // 合伙人注册
const partnerBinding=reqComUrl + '/partner/binding'    // 合伙人绑定
const partnerPage=reqComUrl + '/partner/page/' // 合伙人关系
const distributionOrder=reqComUrl + '/partner/distributionOrder/'    // 合伙人订单
const collectionProduct=reqComUrl + '/umsMemberCollection/collectionProduct'   //新增用户商品收藏
const deleteProduct=reqComUrl + '/umsMemberCollection/deleteProduct'   //取消商品收藏
const uploadFile=reqComUrl + '/pmsPicture/uploadFile'//上传图片
const getPartnerInfo=reqComUrl + '/partner/getPartnerInfo/'//根据id获取合伙人信息
const updatePartnerInfo =reqComUrl + '/partner/updatePartnerInfo'//修改合伙人信息
const dealerStore = reqComUrl + '/partner/option/binding' // 合伙人绑定经销商、门店



/* 营销活动 */

const ismsHouseBuypage = reqComUrl + '/smsHouseBuy/page' // 全屋购列表
const verifySpaceValidation = reqComUrl + '/smsHouseBuy/verifySpaceValidation' //检查用户选择的全屋购空间是否有效
const ismsHouseBuyinfo = reqComUrl + '/smsHouseBuy/info' // 全屋购详情
const mmsSeckillcurrent = reqComUrl + '/mmsSeckill/current' // 秒杀专区正在疯抢
const mmsSeckillsoon = reqComUrl + '/mmsSeckill/soon' // 秒杀专区即将开始
const addSubscribe = reqComUrl + '/wxMsgSubscribe/addActivitySubscribe' // 活动预约提醒
const abolishSubscribe = reqComUrl + '/wxMsgSubscribe/abolishActivitySubscribe' // 活动取消预约提醒
const mmsActivityPage = reqComUrl + '/mmsActivityPage' // 活动页
const queryByTypePage = reqComUrl + '/mmsPoster/queryByType' // 根据海报类型查询
const mmsPosterTypePage = reqComUrl + '/mmsPosterType/queryByLocation' // 查询全部海报类型
const mmsPosterPage = reqComUrl + '/mmsPoster/queryByLocation' // 根据投放位置查询海报
const smsHomeNewProduct = reqComUrl + '/smsHomeNewProduct/page' // 新品首发/精选专区
// const smsHomeNewProduct = reqComUrl + '/app/v1/pmsProduct/list' // 新品首发/精选专区 本地
const mmsSeckillIndex = reqComUrl + '/mmsSeckill/index' // 首页秒杀
const guessYouLike = reqComUrl + '/search/product' // 猜你喜欢
const getCouponInfo = reqComUrl + '/smsCoupon/queryByCouponId/'  /////根据ID查询
const couponApi={
  quryCouponType: reqComUrl + '/smsCouponType/page',// 查询优惠券类型
  couponCenterPage:reqComUrl + '/smsCoupon/couponCenterPage',// 领券中心列表
  receiveCoupon:reqComUrl + '/smsCoupon/receiveCoupon',// 领取优惠券
  queryMyCoupon: reqComUrl + '/smsCoupon/myCoupon', // 查询我的卡券
  queryMyCouponNum :reqComUrl + '/smsCoupon/queryMyCouponNum',// 我的卡券类型数量
  queryHistoryCoupon: reqComUrl + '/smsCoupon/myCouponHistory', // 优惠券历史
  queryDetail:reqComUrl + '/smsCoupon/getCouponDetail', // 优惠券详情
  verification:reqComUrl + '/smsCouponValidUser/verification', // 校验用户信息
  sendSmsCode:reqComUrl + '/smsCouponValidUser/sendSmsCode', //  获取验证码
  validate:reqComUrl + '/smsCouponValidUser/validate', //  优惠卷-短信验证
}


/* 个人中心 */
const decryptGetPhone = reqComUrl + '/login/decryptGetPhone' // 解密绑定手机号
const orderAllList = reqComUrl + '/order/orderAllList' // 订单列表
const orderDetails = reqComUrl + '/order/orderDetails' // 订单详情
const distributionOrderInfo = reqComUrl + '/order/distributionOrderInfo' // 订单详情
const cancelOrder = reqComUrl + '/order/cancelOrder' // 取消订单
const confirmReceipt = reqComUrl + '/order/confirmReceipt' // 确认收货
const queryList = reqComUrl + '/omsOrderRefundApply/queryList' // 退款列表查询
const queryDetail = reqComUrl + '/omsOrderRefundApply/query' // 根据Id查询退款详情
const cancelRefund = reqComUrl + '/omsOrderRefundApply/cancelRefund' // 取消退款
const requestNote = reqComUrl + '/omsOrderRefundApply/requestNote' // 申请退款
const createRefund = reqComUrl + '/omsOrderRefundApply/createRefund' // 保存退款申请
const uploadImg = reqComUrl + '/omsOrderRefundApply/upload' // 退款批量上传凭证
const pageProduct = reqComUrl + '/umsMemberFootprint/pageProduct' // 我的足迹
const queryForPartnerByPage = reqComUrl + '/umsMemberFootprint/queryForPartnerByPage' // 足迹详情列表
const customerOne = reqComUrl + '/partner/customerOne' // 足迹详情头部信息
const collecProduct = reqComUrl + '/umsMemberCollection/pageProduct' // 我的收藏商品
const contentProduct = reqComUrl + '/umsMemberCollection/pageContent' // 我的收藏内容
const changeGender = reqComUrl + '/personalCenter/changeGender' // 个人中心个人资料修改
const dealerPayeeInfo = reqComUrl + '/masDealerPayee/dealerPayeeInfo' // 查询经销商(有效)收款人信息
const bindDealerPayeeSendSms = reqComUrl + '/masDealerPayee/bindDealerPayeeSendSms' // 发送绑定验证码
const validateBindDealerPayee = reqComUrl + '/masDealerPayee/validateBindDealerPayee' // 校验短信验证码
const bindDealerPayee = reqComUrl + '/masDealerPayee/bindDealerPayee' // 绑定收款人

const foundApi={
  // getTemplateStyle: foundComUrl + '/Wechat/GetTemplateStyle', // 首页-获取八大风格
  getRecommendList: reqComUrl + '/ads/getInterestProgramme', // 获取最in推荐
  getRegisterData: reqComUrl + '/crm/getRegisterData', // 报名页获取CRMtoken等入参数据
  queryEncyCategory:reqComUrl + '/cmsContentCategory/categoryPage',// 家居百科类目
  queryEncyclopediaHome: reqComUrl + '/cmsContent/homePage', // 查询家居百科首页列表
  queryEncyclopediaList: reqComUrl + '/cmsContent/queryPageByCategoryId/', // 查询家居百科列表
  queryShowList: reqComUrl + '/cmsContent/show', // 查询友家秀列表
  queryDetail: reqComUrl + '/cmsContent/', // 查询内容详情
  querySkuByContentId: reqComUrl + '/cmsContent/querySkuByContentId/', // 查询内容详情
  thumbsUp: reqComUrl + '/umsMemberThumbsUp/thumbsUp', // 点赞
  removeThumbsUp: reqComUrl + '/umsMemberThumbsUp/', // 取消点赞
  collection: reqComUrl + '/umsMemberCollection/collectionContent', // 收藏
  removeCollection: reqComUrl + '/umsMemberCollection/deleteContent', // 取消收藏
  commentPage:reqComUrl + '/cmsContent/commentList', // 获取评价列表 TODO：接口待定
  commentDel:reqComUrl + '/cmsContent/commentList/delete', // 删除评价 TODO：接口待定
  commentSave:reqComUrl + '/cmsContent/commentList/publish', // 发表评价 TODO：接口待定
  helpPag:reqComUrl + '/cmsContentCategory/helpPage', // 常见问题
  queryHelpPage:reqComUrl + '/cmsContent/queryHelpPageByCategoryId', // 常见问题二级页面查询
  helpDetail:reqComUrl + '/cmsContent', // 常见问题详情页查询
  helpSearch:reqComUrl + '/cmsContent/search', // 常见问题搜索
}

/* 直播 */
const livingList = reqComUrl + '/liveRoom/livingList' // 正在直播列表
const replayList = reqComUrl + '/liveRoom/replayList' // 历史直播列表

// 拼团 砍价
const spellApi={
  checkSpellBuy: reqComUrl + '/mmsSpellBuy/checkSpellBuy', // 拼团校验
  activityList: reqComUrl + '/mmsSpellBuy/', // 根据ID查询
  mmsSpellBuyGroup: reqComUrl + '/mmsSpellBuyGroup/info/', // 根据ID查询拼团详情
  launchCutPrice: reqComUrl + '/mmsCutPrice/launchCutPrice', // 发起砍价
  cutActivity: reqComUrl + '/mmsCutPrice/', // 根据ID查询
  cutPriceList: reqComUrl + '/mmsCutPriceGroup/cutPriceList', // 我的砍价列表
  cutPriceDetail: reqComUrl + '/mmsCutPriceGroup/', //根据ID查询砍价详情页
  halfwayBuy: reqComUrl + '/mmsCutPriceGroup/halfwayBuy/', //提前购买
  cutAKnife: reqComUrl + '/mmsCutPriceGroup/cutAKnife/' //砍一刀
}
// 视频专栏
const video={
  getCategoryUrl: reqComUrl + '/cmsVideoColumn/getCategory/', // 根据栏目ID获取分类
  getColumnByIdUrl: reqComUrl + '/cmsVideoColumn/getColumnById/', // 根据栏目ID获取专栏信息
  getVideoUrl: reqComUrl + '/cmsVideoColumn/getVideo', // 根据栏目ID获取视频
  keepVideoUrl: reqComUrl + '/cmsVideoColumn/keepVideo', // 收藏视频
  unKeepVideoUrl: reqComUrl + '/cmsVideoColumn/unKeepVideo', // 取消收藏视频
  getProductUrl: reqComUrl + '/cmsVideoColumn/getProduct', // 获取视频详情
  addScanNumUrl: reqComUrl + '/cmsVideoColumn/addScanNum' // 增加浏览量
}

module.exports = {

  ismsHouseBuypage,  ismsHouseBuyinfo, loginAuth, bandingUserInfo, getHomePage, getShopActivity,joinShopActivity,region,confirmOrder,createOrder,payOrder,createDepositOrder,componentData,bottomNavBar,queryPageSet,querySkuByPage,
 classifyData, getCarItem, getCarNumber, newAddress, updateDefault, addressList,listByParentCode,partnerPage,distributionOrder,getParamByScene,updateUserAddr,getCouponInfo,verifySpaceValidation,loginLog,
  mmsPosterTypePage,mmsPosterPage,decryptGetPhone,orderAllList,orderDetails,distributionOrderInfo,queryMiniByCode,queryByContentType,sysTheme,collectionProduct,cancelOrder,confirmReceipt,queryList,queryDetail,cancelRefund,requestNote,createRefund,uploadImg,pageProduct,collecProduct,contentProduct,queryForPartnerByPage,customerOne,
  deleteAddress, updateAddress, centerCount, partnerRegister, partnerBinding,   getAddrCode, searchShopData, searchClassify,getGoodsInfoHead,getGoodsImgText,receiveCoupon,shoppingCartCoupons,modifyQuantity,deleteCarGoods,modifyProductAttr,QRCode,qpuListOfVal,deleteProduct,
  uploadFile,getPartnerInfo,updatePartnerInfo,dealerStore,
  getGoodsSkus,nearbyShop,getPricePstCode,recommendShop,recommendGoodsList,validByAreaCode,queryTreeAll,geocode,carAddshop,productCoupons,changeGender,
 partnerRegister, partnerBinding, mmsSeckillcurrent, mmsSeckillsoon, mmsActivityPage, queryByTypePage,couponApi,addSubscribe,abolishSubscribe,guessYouLike,smsHomeNewProduct,mmsSeckillIndex,foundApi,
 dealerPayeeInfo, bindDealerPayeeSendSms, validateBindDealerPayee, bindDealerPayee,livingList,replayList,
 saveUserInfo, queryAllTemplate, insertSubscribeRecord, checkExistSubscribeRecord, insertShareRecord, spellApi,
 saveAccessFootprint,saveQuitFootprint, video
}
